﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

    class KeyInfo
    {
        static void Main(string[] args)
        {
            Console.OutputEncoding = Encoding.UTF8;
            while (true)
            {
                ConsoleKeyInfo key = Console.ReadKey();
                Console.WriteLine();
                Console.WriteLine("Key name: " + key.Key);
                Console.WriteLine("Key number: " + (int)key.Key);
                Console.WriteLine("Special keys: [{0}] ", key.Modifiers);
                Console.WriteLine("Character entered: ", key.KeyChar);
            }
        }
    }

